{
    let obj:{addr:string};
    obj = {addr:"beijing"};

    let obj2:{name:string,age?:number,gender?:string};
    let obj3:{name:string,[key:string]:any};
    obj2 = {name:"zhangsan",age:18,gender:"male"};
    obj3 = {name:"zhangsan",age:18,gender:"male",height:1.88};

    let fn:(a:number,b:number)=>number;
    fn = (a,b)=>a+b;

    let arr:(number|string)[];
    arr = [1,2,3,"4"];
    // 元组类型
    let arr2:[number,string];
    arr2 = [1,"2"];
    let arr3:Array<number>;
    arr3 = [1,2,3];

    // 枚举类型
    enum Gender{
        Male,
        Female
    }
    let obj4:{name:string,gender:Gender};
    obj4 = {name:"zhangsan",gender:Gender.Male};

    // 别名
    type User = {
        name:string,
        age:number
    }
    let user:User;
    user = {name:"zhangsan",age:18}

    // 接口
    interface User2{
        name:string,
        age:number
    }
    let user2:User2;
    user2 = {name:"zhangsan",age:18}
}